<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<base href="{:get_site_domain()}" />
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<meta name="keywords" content="<empty name="seo.keywords">{$_global.site_keywords}<else/>{$seo.keywords|Input::forShow}</empty>"></meta>
<meta name="description" content="<empty name="seo.description">{$_global.site_description}<else/>{$seo.description|Input::forShow}</empty>"></meta>
<meta name="generator" content="{$_global.software_name} {$_global.software_version}" />
<meta name="author" content="{$_global.software_producer}" />
<meta name="copyright" content="{$_global.software_copyright}" />
<title><empty name="seo.title">{$_global.site_name} - {$_global.site_slogan}<else/>{$seo.title|Input::forShow} - {$_global.site_name}</empty></title>
<link rel="shortcut icon" href="http://l.yimg.com/a/i/us/sch/gr/answers_favicon.ico" />
<link rel="alternate" type="application/rss+xml" title="{$_global.site_name} : {$Think.lang.rss_latest_question}" href="{:U('Feed/category')}">
<link type="text/css" rel="stylesheet" href="__TMPL__/Home/style.css" />
<!--
<script type="text/javascript" src="http://www.google.com/jsapi"></script>
<script type="text/javascript">google.load("jquery", "1.4.2");</script>
-->
<script type="text/javascript">
var APP = '__APP__';
var SITE_URL = '{$_global.site_url}';
var LOGIN_URL = '{:U("Account/login")}';
var WAIT_TIME = {$waitSecond} * 1000;
var UID = '{$_user.user_id}';
var LANG = {$jsLangPackage};
</script>
<script type="text/javascript" src="__PUBLIC__/Js/jquery.core.js"></script>
<script type="text/javascript" src="__PUBLIC__/Js/jquery.mouseDelay.js"></script>
<script type="text/javascript" src="__PUBLIC__/Js/artDialog/artDialog.min.js"></script>
<script type="text/javascript" src="__TMPL__/Home/qa.js"></script>
<script type="text/javascript">
$(function(){
	if(($.browser.msie) && ($.browser.version == '6.0')){
		$.dialog({
			title: 'Warnning',
			content: '<p>Your browser version is too low, please update your browser. Why not try about Firefox or Chrome?</p>',
			lock: true
		});
	}
    var askBoxTips = '{$Think.lang.ask_box_tips}';
    $('#banner-ask').focus(function(){
        if($(this).val() == askBoxTips){
            $(this).val('');
        }
    }).blur(function(){
        if($(this).val() == ''){
            $(this).val(askBoxTips);
        }
    });

    var searchBoxTips = '{$Think.lang.search_box_tips}';
    var keywordRequired = '{$Think.lang.search_keyword_required}';
    $('#input-search').focus(function(){
        if($(this).val() == searchBoxTips || $(this).val() == keywordRequired){
            $(this).val('').removeClass('normal').addClass('highlight');
        }
    }).blur(function(){
        if($(this).val() == ''){
            $(this).val(searchBoxTips).removeClass('highlight').addClass('normal');
        }
    });

    $('#btn-search').click(function(){
        var keyword = $.trim($('#input-search').val());
        if(keyword == '' || keyword == searchBoxTips || keyword == keywordRequired){
            $('#input-search').val(keywordRequired).addClass('highlight');
            return false;
        }
    });

    $('#qan-nav-browser').mouseDelay().hover(
        function(){
            $('#qan-nav-browser-menu').show();
        },
        function(){
            $('#qan-nav-browser-menu').hide();
        }
    );

    $('#qan-nav-activity').mouseDelay().hover(
        function(){
            $('#qan-nav-activity-menu').show();
        },
        function(){
            $('#qan-nav-activity-menu').hide();
        }
    );

});
</script>
</head>
<body>
<div id="wrap">
    <div id="page-header">
        <div class="headerbar sp">
            <div class="top-nav">
                <div class="custom">
                    <ul id="top-custom-nav">
                        <li></li>
                    </ul>
                </div>
                <div class="member">
                    <ul id="member-nav">
                        <li class="col1"><empty name="_user.user_id"><a href="{:U('Register/index')}">{$Think.lang.register}</a><else/><a href="{$_user.user_id|format_user_url=$_user['username']}">{$_user.username}</a></empty></li>
                        <li class="col2"><empty name="_user.user_id"><a href="{:U('Account/login')}">{$Think.lang.login}</a><else/><a href="{:U('Account/logout')}">{$Think.lang.logout}</a></empty></li>
                        <in name="_user.admin_group" value="1,2,3">
                        <li class="col3"><a href="{:U('Modcp/index')}">{$Think.lang.mcp}</a></li>
                        </in>
                        <if condition="$_user['user_id'] AND $_userGroup['allow_invite']">
                        <li class="col4"><a href="{:U('Invitation/index')}">{$Think.lang.invitation}</a></li>
                        </if>
                        <li class="col5 last"><a href="{:U('Faq/index')}">{$Think.lang.help}</a></li>
                    </ul>
                </div>
            </div>
            <div class="qqas">
                <div class="logo"><img src="{$_global.site_logo}" alt="{$_global.site_name}"></a></div>
                <div id="ad_global_header_top">{ad:global_header_top}</div>
            </div>
        </div>
    <div class="tabbed-content">
        <ul id="qan-nav" class="tabs">
            <li id="qan-nav-home" class="<eq name="Think.module_name" value="Index">current</eq>"><a href="{$_global.site_url}">{$Think.lang.home}</a></li>
            <li id="qan-nav-browser" class="<eq name="Think.module_name" value="Category">current</eq>">
                <a href="{:U('Category/index')}">{$Think.lang.browser_categories}</a>
                <ul id="qan-nav-browser-menu" class="dropdown">
                    <volist name="_topCategories" id="vo">
                    <li><a href="{$vo.category_id|format_category_url}">{$vo.name}</a></li>
                    </volist>
                </ul>
            </li>
            <eq name="_global.tag_enable" value="1">
            <li id="qan-nav-tags" class="<eq name="Think.module_name" value="Tag">current</eq>"><a href="{:U('Tag/listing')}">{$Think.lang.tags}</a></li>
            </eq>
            <li id="qan-nav-medals" class="<eq name="Think.module_name" value="Medal">current</eq>"><a href="{:U('Medal/index')}">{$Think.lang.medals}</a></li>
            <li id="qan-nav-teams" class="<eq name="Think.module_name" value="Team">current</eq>"><a href="{:U('Team/index')}">{$Think.lang.teams}</a></li>
            <notempty name="_user.user_id">
            <li id="qan-nav-activity" class="<eq name="Think.module_name" value="User">current</eq>">
                <a href="{$_user.user_id|format_user_url=$_user['username']}">{$Think.lang.my_activity}</a>
                <ul id="qan-nav-activity-menu" class="dropdown">
                    <li><a href="{:U('Team/myTeam')}">{$Think.lang.my_team}</a></li>
                    <li><a href="{:U('User/qa',array('uid'=>$_user['user_id'],'type'=>'answered'))}">{$Think.lang.my_qa}</a></li>
                    <li><a href="{:U('User/network',array('uid'=>$_user['user_id'],'type'=>'network'))}">{$Think.lang.my_network}</a></li>
                    <li><a href="{:U('User/preference',array('uid'=>$_user['user_id'],'type'=>'profile'))}">{$Think.lang.user_edit_preferences}</a></li>
                </ul>
            </li>
            </notempty>
        </ul>
        <div id="qan-banner">
            <ul>
                <li class="qan-banner-ask">
                    <form action="{:U('Question/ask')}" method="POST">
                        <h2><a href="{:U('Question/ask')}">{$Think.lang.ask}</a></h2>
                        <input id="banner-ask" class="default" type="text" name="title" maxlength="110" value="{$Think.lang.ask_box_tips}" />
                        <span class="cta"><input class="btn" type="submit" value="{$Think.lang.continue}" /></span>
                    </form>
                </li>
                <li class="qan-banner-answer">
                    <div>
                        <h2><a href="{:U('Category/index',array('status'=>'open'))}">{$Think.lang.answer}</a></h2>
                    </div>
                </li>
                <li class="qan-banner-discover">
                    <div>
                        <h2><a href="{:U('Category/index',array('status'=>'resolved'))}">{$Think.lang.discover}</a></h2>
                    </div>
                </li>
            </ul>
        </div>
        <neq name="Think.module_name" value="Search">
        <div id="header-searchbox">
            <form action="{:U('Search/index')}" method="POST">
                <input id="input-search" class="default input normal" type="text" size="40" name="keyword" value="{$Think.lang.search_box_tips}" />
                <input id="btn-search" class="button" type="submit" value="{$Think.lang.search_answers}" />
                <span><a href="{:U('Search/index')}">{$Think.lang.search_advanced}</a></span>
                <span><a href="{:U('Search/google')}">{$Think.lang.search_with_google}</a></span>
            </form>
        </div>
        </neq>
    </div>
    <div id="ad_global_header_bottom">{ad:global_header_bottom}</div>
